package com.chilly.controller;

import com.chilly.designpattern.event.DemoPublisher;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * Created by Chilly Cui on 2020/11/18.
 */
@RestController
public class EventController {
    @Autowired
    private DemoPublisher demoPublisher;

    @RequestMapping("/event")
    public void testQuery() {
        demoPublisher.publish("hello");
    }
}
